<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <script>
    //  登录 
    var zh = "yqy"
    var mm = "1234"
    var name = prompt("请输入账号")
    // 判断 账号是否为提供的账号
    if (zh == name){
        // 嵌套 判断密码
        var zz = prompt("请输入密码：")
        if (mm == zz){
            alert("登录成功")
        }else{
            alert("密码错误") }
        }else{
            alert("账号错误")
        }
   
  </script>
</html>